package model.command;
import controller.KeyListeners.KeyListenerSet;
import model.playable.unit.Colonist;
/**
 *
 * @author joseph
 */
public class ConstructCapital extends Command{
    private Colonist colonist;
    public ConstructCapital(Colonist colonist){
        super();
        setColonist(colonist);
    }
    @Override
    public void attachToListener() {
        getListeners().attachToEnterListener(clone());
    }
    @Override
    public ConstructCapital clone() {
        return new ConstructCapital(colonist);
    }
    @Override
    public void executeCommand() {
        colonist.constructCapital();
    }
    private void setColonist(Colonist colonist) {
        this.colonist = colonist;
    }
    @Override
    public String toString(){
        return "Construct Capital";
    }
}
